
fn main() {
    enum Message {
        Hello {id: i32}
    }

    let msg = Message::Hello {id: 5};

    match msg {
        Message::Hello {id: id_variable@ 3..=7} => {
            println!("Found an id in range : {} ", id_variable);
        },
        Message::Hello {id:10...12} => {
            println!("Found id between 10 to 12");
        },
        Message::Hello {id} => {
            println!("Found some other id : {}", id);
        },
    }
}


